SELECT table_name FROM information_schema.tables WHERE table_schema='public' AND table_type='BASE TABLE';
postgres=# \d schema.tablename;
postgres=# \dt+Code language: PHP (php)